package com.itstyle.quartz.web;

import com.itstyle.quartz.entity.Menu;
import com.itstyle.quartz.service.impl.MenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/menu")
public class MenuController {

    @Autowired
    private MenuService menuService;

    @RequestMapping("/findByUserId")
    public List<Menu> findByUserId(){
        return menuService.findByUserId();
    }
}
